<?php

namespace app\modules\admin\models;

use Yii;

/**
 * This is the model class for table "cw_admin".
 *
 * @property integer $admin_id
 * @property string $admin_username
 * @property string $admin_password
 */
class CwAdmin extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public $new_password = "";
    public $again_password = "";
    
    public static function tableName()
    {
        return 'cw_admin';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['admin_username', 'admin_password','new_password'], 'required'],
            [['admin_username', 'admin_password'], 'string', 'max' => 255],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'admin_id' => 'Admin ID',
            'admin_username' => '帐号',
            'admin_password' => '密码',
            'new_password' => '新密码',
            'again_password' => '再次确定'
        ];
    }
}
